<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
  <meta charset="UTF-8">
  <title>添加课程</title>
  <style>
    .form-group { margin-bottom: 15px; }
    label { display: block; margin-bottom: 5px; }
    input { width: 300px; padding: 8px; border: 1px solid #ddd; border-radius: 4px; }
    button { padding: 10px 20px; background-color: #4CAF50; color: white; border: none; border-radius: 4px; cursor: pointer; }
  </style>
</head>
<body>
<h2>添加课程</h2>
<form action="${pageContext.request.contextPath}/course/add" method="post">
  <div class="form-group">
    <label>课程代码:</label>
    <input type="text" name="course" required>
  </div>
  <div class="form-group">
    <label>课程名称:</label>
    <input type="text" name="name" required>
  </div>
  <div class="form-group">
    <label>教师ID:</label>
    <input type="number" name="teacher_id" required>
  </div>
  <div class="form-group">
    <label>学分:</label>
    <input type="number" name="credit" required>
  </div>
  <button type="submit">提交</button>
</form>
</body>
</html>